<!DOCTYPE html>
<html lang="en" xmlns:th="http://www.thymeleaf.org">
<head>
    <base href="http://localhost:8080/fan/">
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>全部订单</title>
    <script src="js/jquery.js"></script>
    <link rel="icon" href="https://zhangxu-1023.oss-cn-nanjing.aliyuncs.com/images/logo/minilogo.png">
    <link rel="stylesheet" href="css/mine/myfantuan.css">
    <link rel="stylesheet" href="css/mine/order.css">
    <link rel="stylesheet" href="css/details/details_bottom.css">
    <link rel="stylesheet" href="css/details/details_header.css">
    <link rel="stylesheet" href="layui/css/layui.css">
</head>
<body>
<!-- ----------------头部------------------------- -->
<div class="header">
    <div class="top-nav ">
        <div class="layui-main top-main layui-row">
            <div class="layui-col-xs4">
                <span>&nbsp</span>
            </div>
            <div class="layui-col-xs4">
                <span>&nbsp</span>
            </div>
            <div class="layui-col-xs4">
                <ul class="layui-nav" lay-filter="">
                    <li class="layui-nav-item" ><a href="customer/user_details" class="title" th:text="${cusName}">登录/注册</a></li>
                    <li class="layui-nav-item" ><a href="#" class="title">帮助中心</a></li>
                    <li class="layui-nav-item">
                        <a href="javascript:;" class="title">我的饭团</a>
                        <dl class="layui-nav-child"> <!-- 二级菜单 -->
                            <dd><a href="customer/getAllOrder?status=3&pageNum=1">订单中心</a></dd>
                            <dd><a href="customer/getAllCoupon?status=1&pageNum=1">我的优惠券</a></dd>
                            <dd><a href="customer/getShopCollect">我的收藏</a></dd>
                        </dl>
                    </li>

                </ul>
            </div>
        </div>
    </div>
    <div class="layui-row header-tip">
        <!--      logo      -->
        <div class="layui-col-xs3 logo-input">
            <a href="shop/shopsift/1" title="饭团网" class="logo-img">
                <img src="https://zhangxu-1023.oss-cn-nanjing.aliyuncs.com/images/logo/mylogo.png"  width="200" height="72">
            </a>
        </div>
        <!--    搜索    -->
        <div class="layui-col-xs6 search-box">
            <form class="layui-form layui-form-pane" action="">
                <div class="layui-form-item searchbox-input">
                    <div class="layui-input-block" style="margin-left: 10px">
                        <input style="border: 2px solid rgb(255,107,55);width: 80%;display: block;float: left" type="text" name="title" autocomplete="off"
                               placeholder="点此进入美食猩球" class="layui-input" id="es_input">
                        <div class="layui-btn-container" style="display: block;float: left">
                            <button type="button" class="layui-btn layui-btn-sm layui-btn-radius layui-btn-danger search-btn" id="es_btn">去觅食</button>
                        </div>
                    </div>
                </div>
            </form>
        </div>
    </div>
</div>

<div class="layui-main">
    <!-- --------------我的饭团 左侧栏------------------------ -->
    <div class="orders-container">
        <ul class="layui-nav layui-nav-tree layui-inline" lay-filter="demo" style="margin-right: 10px;">
            <li class="layui-nav-item"><a href="root/personal_center/myfantuan.html">我的饭团</a></li>
            <li class="layui-nav-item layui-nav-itemed">
                <a href="javascript:;" class="title">订单</a>
                <dl class="layui-nav-child">
                    <dd><a href="customer/getAllOrder?status=3&pageNum=1" class="title_next">全部订单</a></dd>
                    <dd><a href="customer/getAllOrder?status=1&pageNum=1" class="title_next">待付款</a></dd>
                    <dd><a href="customer/getAllOrder?status=2&pageNum=1" class="title_next">待评论</a></dd>
                </dl>
            </li>
            <li class="layui-nav-item layui-nav-itemed">
                <a href="javascript:;" class="title">我的优惠券</a>
                <dl class="layui-nav-child">
                    <dd><a href="customer/getAllCoupon?status=1&pageNum=1" class="title_next">可用券</a></dd>
                    <dd><a href="customer/getAllCoupon?status=0&pageNum=1" class="title_next">失效券</a></dd>
                </dl>
            </li>
            <li class="layui-nav-item layui-nav-itemed">
                <a href="javascript:;" class="title">我的收藏</a>
                <dl class="layui-nav-child">
                    <dd><a href="customer/getShopCollect" class="title_next">收藏店铺</a></dd>
                </dl>
            </li>
            <li class="layui-nav-item">
                <a href="customer/user_details">个人信息</a>
            </li>
        </ul>
        <!-- -----------------orders-body-------------------- -->
        <div class="collcetshop pro">
            <ul>
                <li th:each="shop:${myCollectShop}">
                    <a th:href="'http://localhost:8080/fan/shop/'+${shop.shopId}" class="proimg"><img th:src="${shop.shopMainImg}"></a>
                    <h4><a th:href="'http://localhost:8080/fan/shop/'+${shop.shopId}" th:text="${shop.shopName}">熊猫不走生日蛋糕（苏州店）</a></h4>
                    <label class="proscoreimg"><i></i><i></i><i></i><i></i><i></i></label>
                    <label class="proscore" th:text="${shop.shopScore}">5</label><label>分</label>
                    <script>
                        var score = $(".proscore:last").text();
                        for (var i=1;i<=5;i++) {
                            if(score >= i) {
                                $(".proscoreimg:last").children().eq(i-1).css("background-image","url(https://zhangxu-1023.oss-cn-nanjing.aliyuncs.com/images/filter_page/2022-10-20/2937015492394b9eb733593d649ad0e0index-wellreceived-icon.svg)");
                            } else if( score > (i-1) && score < i ) {
                                $(".proscoreimg:last").children().eq(i-1).css("background-image","url(https://zhangxu-1023.oss-cn-nanjing.aliyuncs.com/images/details_shop/2022-10-20/banxing.svg)");
                            } else {
                                $(".proscoreimg:last").children().eq(i-1).css("background-image","url(https://zhangxu-1023.oss-cn-nanjing.aliyuncs.com/images/details_shop/2022-10-20/kongxing.svg)");
                            }
                        }
                    </script>
                    <!--                            <a th:href="'http://localhost:8080/fan/shop/'+${shop.shopId}" class="comment">-->
                    <!--                                <span>1234</span>-->
                    <!--                                <span>条评论</span>-->
                    <!--                            </a>-->
                    <span class="sty" th:text="${shop.shopAddressDetail}">观前街地区</span>
                    <span class="sty">人均 ￥<span th:text="${shop.shopAvgCost}">141.0</span></span>
                </li>


            </ul>
        </div>
        <!--分页-->
        <!--        <input type="hidden" id="pagenum" th:value="${orders.current}">-->
        <!--        <input type="hidden" id="total" th:value="${orders.total}">-->
        <!--        <div id="demo2-1" class="page"></div>-->
    </div>
    <!-- ---------------------------底部-------------------------------- -->
<!--    <div class="layui-row">-->
<!--        <div class="layui-edge-bottom detail-bottom">-->
<!--            <div class="layui-col-xs2">-->
<!--                关于饭团-->
<!--            </div>-->
<!--            <div class="layui-col-xs2">-->
<!--                加入我们-->
<!--            </div>-->
<!--            <div class="layui-col-xs2">-->
<!--                商家入驻-->
<!--            </div>-->
<!--            <div class="layui-col-xs2">-->
<!--                帮助中心-->
<!--            </div>-->
<!--            <div class="layui-col-xs2">-->
<!--                手机APP-->
<!--            </div>-->
<!--            <div class="layui-col-xs2">-->
<!--                <a href="javascript:;" title="@张旭 @刘海萍 @刘丽 @商建">@作者</a>-->
<!--            </div>-->
<!--        </div>-->
<!--    </div>-->
</div>


<iframe align="center" width="100%" height="560px" src="details/details_bottom.html"
        frameborder="no" border="0" marginwidth="0" marginheight="0" scrolling="no">
</iframe>


<script src="layui/layui.js"></script>
<script src="js/customer/personal_center/myfantuan.js"></script>
<script src="js/elasticsearch_util.js"></script>
<script>
    layui.use('element', function(){
        var element = layui.element; //导航的hover效果、二级菜单等功能，需要依赖element模块
        //导航点击事件
        element.on('nav(demo)', function(elem){
            //console.log(elem)
            layer.msg(elem.text());
        });
    });
    layui.use(['laypage', 'layer'], function(){
        var pagenum = document.getElementById("pagenum").value;
        var total = document.getElementById("total").value;
        var laypage = layui.laypage
            ,layer = layui.layer;
        laypage.render({
            elem: 'demo2-1'
            ,count: total
            ,curr:pagenum
            ,limit:3
            ,theme: '#FF6B37'
        });
    });
</script>
</body>
</html>
